<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: 性感周周
  Date: 2021/12/3
  Time: 9:49
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
    <script src="js/jquery-1.9.1.min.js"></script>
    <script src="js/fileupload.js"></script>
    <script src="My97DatePicker/WdatePicker.js"></script>
    <script src="bootstrap-4.6.0-dist/js/bootstrap.min.js"></script>
    <link rel="stylesheet" href="bootstrap-4.6.0-dist/css/bootstrap.min.css">
</head>
<body>
    <div class="row">
        <div class="col-sm-2">
            <jsp:include page="/layout/left1.jsp"></jsp:include>
        </div>
        <div class="col-sm-10">
            <form action="">
                仓库编号 : <input type="type" name="snowid" value="${map.snowid}">
                库区 :<input type="type" name="kuqu" value="${map.kuqu}">
                物料编号:<input type="type" name="wid" value="${map.wid}"> <br>
                市场价:
                <input type="text" name="pricex" value="${map.pricex}">--------
                <input type="text" name="priced" value="${map.priced}"> <br>
                数量:<input type="text" name="numx" value="${map.numx}">--------
                <input type="text" name="numd" value="${map.numd}"> <br>
                金额:<input type="text" name="sumpricex" value="${map.sumpricex}">--------
                <input type="text" name="sumpriced" value="${map.sumpriced}"> <br>
                <br><select name="order">
                    <option value="">请选择</option>
                    <option value="shouhuoid"${map.order=="shouhuoid"?'selected':''}>仓库编号</option>
                    <option value="ckname"${map.order=="ckname"?'selected':''}>仓库名称</option>
                    <option value="kuqu"${map.order=="kuqu"?'selected':''}>库区</option>
                    <option value="cangwei"${map.order=="cangwei"?'selected':''}>仓位
                    </option>
                </select>
                <select name="orderby">
                    <option value="">请选择</option>
                    <option value="asc" ${map.orderby=="asc"?'selected':''}>正序</option>
                    <option value="desc"${map.orderby=="desc"?'selected':''}>倒序</option>
                </select>
                <input type="submit" value="查询">
            </form>
            <table class="table table-primary table-hover table-striped">
                <tr>
                    <td></td>
                    <td>序号</td>
                    <td>仓库编号</td>
                    <td>仓库名称</td>
                    <td>库区</td>
                    <td>仓位</td>
                    <td>物料编号</td>
                    <td>物料名称</td>
                    <td>市场价</td>
                    <td>数量</td>
                    <td>金额</td>
                    <td>仓管员工号</td>
                    <td>仓管员</td>
                    <td>备注</td>
                </tr>
                <c:forEach items="${list}" var="s">
                    <tr>
                        <td></td>
                        <td>${s.shouhuoid}</td>
                        <td>${s.ckid}</td>
                        <td>${s.ckname}</td>
                        <td>${s.kuqu}</td>
                        <td>${s.cangwei}</td>
                        <td>${s.wid}</td>
                        <td>${s.wname}</td>
                        <td>${s.price}</td>
                        <td>${s.num}</td>
                        <td>${s.sumprice}</td>
                        <td>${s.uid}</td>
                        <td>${s.uname}</td>
                        <td>${s.beizhu}</td>
                    </tr>
                </c:forEach>
                <tr>
                    <td colspan="15">
                        <nav aria-label="Page navigation example">
                            <ul class="pagination">
                                <li class="page-item"><a class="page-link" href="javaScript:go(1)">First</a></li>
                                <li class="page-item"><a class="page-link" href="javaScript:go(${page.getPageNum()-1})">Previous</a></li>
                                <li class="page-item"><a class="page-link" href="#">${page.getPageNum()}/${page.getPages()}</a></li>
                                <li class="page-item"><a class="page-link" href="javaScript:go(${page.getPageNum()+1})">Next</a></li>
                                <li class="page-item"><a class="page-link" href="javaScript:go(${page.getPages()})">Last</a></li>
                            </ul>
                        </nav>
                    </td>
                </tr>
            </table>
        </div>
    </div>
</body>
<script>
    function go(pageNum) {
        location="list.do?pageNum="+pageNum+"&"+$("form").serialize();
    }
</script>
</html>
